import { ColumnProps } from "@/components/Table/type";
import { SchemaProps } from "@/components/Form/type";
export const columns: ColumnProps[] = [
  { type: "index", label: "#", width: 50 },
  { prop: "tenantId", label: "租户编号", search: { el: "input" } },
  { prop: "tenantName", label: "租户名称", search: { el: "input" } },
  { prop: "expireTime", label: "过期时间" },
  { prop: "action", label: "操作", width: 150, fixed: "right" }
];

export const schemas: SchemaProps[] = [
  {
    field: "tenantId",
    label: "租户编号",
    required: true,
    disabled: row => {
      return !!row.id;
    }
  },
  {
    field: "tenantName",
    label: "租户名称",
    required: true
  },
  {
    field: "expireTime",
    label: "过期时间",
    el: "datePicker",
    elProps: {
      style: {
        width: "100%"
      }
    }
  }
];
